package cn.wolfcode.service;

import cn.wolfcode.domain.Department;
import cn.wolfcode.qo.QueryObject;
import com.github.pagehelper.PageInfo;

import java.util.List;

/**
 * 部门Service接口
 */
public interface IDepartmentService {
    /**
     * 部门新增
     *
     * @param department
     */
    void save(Department department);

    /**
     * 部门删除
     *
     * @param id
     */
    void delete(Long id);

    /**
     * 部门新增
     *
     * @param department
     */
    void update(Department department);

    /**
     * 根据ID查部门
     *
     * @param id 传入部门的ID
     * @return 根据ID 查询部门对象
     */
    Department get(Long id);

    /**
     * 查询所有
     *
     * @return
     */
    List<Department> listAll();

    PageInfo<Department> query(QueryObject qo);
}